.voice-generation-container {
  margin: 0 auto;
  padding: 40px 20px;
  min-height: 100vh;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* 工具卡片样式 */
.tool-card {
  background: rgba(255, 255, 255, 0.95);
  border-radius: 16px;
  padding: 30px;
  margin-bottom: 30px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.tool-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

/* 翻译卡片特殊样式 */
.translation-card {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(240, 245, 255, 0.95) 100%);
  border-left: 4px solid #409EFF;
}

/* 语音合成卡片特殊样式 */
.speech-card {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(245, 255, 250, 0.95) 100%);
  border-left: 4px solid #67C23A;
}

/* 卡片标题样式 */
.card-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  color: #303133;
  margin-bottom: 10px;
  font-weight: 600;
}

.card-title .icon {
  font-size: 28px;
}

/* 卡片描述样式 */
.card-desc {
  font-size: 16px;
  color: #606266;
  margin-bottom: 25px;
  line-height: 1.5;
}

/* 翻译内容区域样式 */
.translation-content {
  width: 100%;
}

/* 语音合成内容区域样式 */
.speech-content {
  width: 100%;
}

.btn-animate {
  position: relative;
  width: 130px;
  height: 40px;
  line-height: 40px;
  border: none;
  border-radius: 5px;
  background: #027efb;
  color: #fff;
  text-align: center;
}


.btn-animate__surround {
  &::before, &::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    background: #027efb;
    transition: all 0.3s ease;
  }
  &::before { height: 0%; width: 2px;}
  &::after { width: 0%; height: 2px; }

  &:hover {
    background: transparent;
    &::before { height: 100%; }
    &::after { width: 100%; }
  }

  & > span {
    display: block;

    &:hover { color: #027efb;
      &::before { height: 100%; }
      &::after { width: 100%; }
    }

    &::before, &::after { content: ''; position: absolute; left: 0; bottom: 0; background: #027efb; transition: all 0.3s ease;}
    &:before { width: 2px; height: 0%; }
    &:after { width: 0%; height: 2px; }
  }
}

.header {
  text-align: center;
  margin-bottom: 40px;
}

.header h1 {
  font-size: 36px;
  color: #fff;
  margin-bottom: 10px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.header p {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.9);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.main-content {
  width: 900px;
  margin: 0 auto;
  padding: 0;
}

/* 输入组样式 */
.input-group {
  margin-bottom: 20px;
}

.input-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #303133;
  font-size: 14px;
}

.input-group textarea {
  width: 100%;
  padding: 12px;
  border: 2px solid #dcdfe6;
  border-radius: 8px;
  font-size: 14px;
  resize: vertical;
  transition: border-color 0.3s ease;
  font-family: inherit;
}

.input-group textarea:focus {
  outline: none;
  border-color: #409EFF;
  box-shadow: 0 0 0 2px rgba(64, 158, 255, 0.1);
}

.input-group textarea[readonly] {
  background-color: #f5f7fa;
  border-color: #e4e7ed;
  cursor: not-allowed;
}

/* 字符计数样式 */
.char-count {
  text-align: right;
  font-size: 12px;
  color: #909399;
  margin-top: 5px;
}

/* 翻译操作按钮区域 */
.translate-actions {
  display: flex;
  gap: 15px;
  margin-bottom: 20px;
}

.translate-btn, .copy-btn {
  transition: all 0.3s ease;
}

.translate-btn:hover {
  transform: translateY(-1px);
}

/* 结果区域样式 */
.result-section {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid #e4e7ed;
}

/* 使用翻译结果按钮区域 */
.use-translation {
  text-align: right;
  margin-top: 10px;
}

.form-group {
  margin-bottom: 30px;
}

.form-row {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 20px;
  margin-bottom: 30px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #303133;
}

.full-width {
  width: 100%;
}

.voice-tag {
  font-size: 16px;
  padding: 8px 16px;
}

.slider-container {
  display: flex;
  align-items: center;
  gap: 15px;
}

.rate-value {
  min-width: 50px;
  font-weight: 600;
  color: #409EFF;
}

.action-buttons {
  display: flex;
  gap: 15px;
  justify-content: center;
  margin: 30px 0;
}

.generate-btn, .play-btn {
  min-width: 150px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(64, 158, 255, 0.3);
}

.generate-btn:hover, .play-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(64, 158, 255, 0.4);
}

.output-section {
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1px solid #e4e7ed;
}

.audio-player {
  text-align: center;
  margin-bottom: 20px;
}

.audio-player h3 {
  margin-bottom: 15px;
  color: #303133;
}

.audio-controls {
  width: 100%;
  max-width: 400px;
}

/* 响应式设计调整 */
@media (max-width: 768px) {
  .main-content {
    width: 100%;
    padding: 0 10px;
  }
  
  .tool-card {
    padding: 20px 15px;
    margin-bottom: 20px;
  }
  
  .card-title {
    font-size: 20px;
  }
  
  .translate-actions {
    flex-direction: column;
  }
  
  .translate-actions button {
    width: 100%;
  }
}

.download-section {
  text-align: center;
}

.message-alert {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 2000;
}

@media (max-width: 768px) {
  .voice-generation-container {
    padding: 20px 10px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  }
  
  .main-content {
    padding: 30px 20px;
    margin: 0 10px;
  }
  
  .form-row { grid-template-columns: 1fr; }
  .action-buttons { flex-direction: column; align-items: center; }
  .header h1 { font-size: 28px; }
  .header p { font-size: 16px; }
  
  .btn-animate{
    position: relative;
    top: 10px;
    left: 10px;
    margin-bottom: 15px;
    display: inline-block;
  }
}
